@tailwind base;
@tailwind components;
@tailwind utilities;

body {
  font-family: -apple-system-font,BlinkMacSystemFont,Helvetica Neue,PingFang SC,Hiragino Sans GB,Microsoft YaHei UI,Microsoft YaHei,Arial,sans-serif;
  color: #4c4e4d;
  font-size: 16px;
  background: #f4f4f4;
  line-height: 1.6;
}

/* 暗黑模式样式 */
.dark body {
  color: #e5e7eb;
  background: #111827;
}

/* Element Plus 组件暗黑模式适配 */
.dark .el-card {
  background-color: #374151;
  border-color: #4b5563;
}

.dark .el-form-item__label {
  color: #d1d5db;
}

.dark .el-input__inner {
  background-color: #374151;
  border-color: #4b5563;
  color: #e5e7eb;
}

.dark .el-textarea__inner {
  background-color: #374151;
  border-color: #4b5563;
  color: #e5e7eb;
}

.dark .el-button--default {
  background-color: #374151;
  border-color: #4b5563;
  color: #e5e7eb;
}

.dark .el-table {
  background-color: #374151;
  color: #e5e7eb;
}

.dark .el-table th {
  background-color: #4b5563;
  color: #e5e7eb;
}

.dark .el-table td {
  border-color: #4b5563;
}

.dark .el-pagination {
  color: #e5e7eb;
}

.dark .el-pagination button {
  background-color: #374151;
  color: #e5e7eb;
}

/* 暗黑模式下对话框组件样式 */
.dark .el-dialog {
  background-color: #1f2937;
  border: 1px solid #374151;
}

.dark .el-dialog__header {
  background-color: #1f2937;
  border-bottom: 1px solid #374151;
  color: #e5e7eb;
}

.dark .el-dialog__body {
  background-color: #1f2937;
  color: #e5e7eb;
}

.dark .el-dialog__footer {
  background-color: #1f2937;
  border-top: 1px solid #374151;
}

/* 暗黑模式下上传组件样式 */
.dark .el-upload {
  border-color: #4b5563;
}

.dark .el-upload:hover {
  border-color: #6b7280;
}

.dark .el-upload-dragger {
  background-color: #374151;
  border-color: #4b5563;
}

.dark .el-upload-dragger:hover {
  border-color: #6b7280;
}

/* 暗黑模式下选择器样式 */
.dark .el-select-dropdown {
  background-color: #374151;
  border-color: #4b5563;
}

.dark .el-select-dropdown__item {
  color: #e5e7eb;
}

.dark .el-select-dropdown__item:hover {
  background-color: #4b5563;
}

.dark .el-select-dropdown__item.selected {
  background-color: #1d4ed8;
  color: #ffffff;
}

/* 暗黑模式下switch开关样式 */
.dark .el-switch__core {
  background-color: #4b5563;
  border-color: #4b5563;
}

.dark .el-switch.is-checked .el-switch__core {
  background-color: #1d4ed8;
  border-color: #1d4ed8;
}

/* 暗黑模式下标签页样式 */
.dark .el-tabs__item {
  color: #d1d5db;
}

.dark .el-tabs__item:hover {
  color: #e5e7eb;
}

.dark .el-tabs__item.is-active {
  color: #60a5fa;
}

.dark .el-tabs__nav-wrap::after {
  background-color: #374151;
}

/* 暗黑模式下分割线样式 */
.dark .el-divider {
  border-color: #4b5563;
}

.dark .el-divider__text {
  background-color: #1f2937;
  color: #e5e7eb;
}

/* 暗黑模式下面包屑导航样式 */
.dark .el-breadcrumb__item .el-breadcrumb__inner {
  color: #d1d5db;
}

.dark .el-breadcrumb__item .el-breadcrumb__inner:hover {
  color: #60a5fa;
}

[type='text']:focus, [type='email']:focus, [type='url']:focus, [type='password']:focus, [type='number']:focus, [type='date']:focus, [type='datetime-local']:focus, [type='month']:focus, [type='search']:focus, [type='tel']:focus, [type='time']:focus, [type='week']:focus, [multiple]:focus, textarea:focus, select:focus {
  box-shadow: 0 0 0 1px transparent inset!important;
}